<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org"
	xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<title>YogaClub Info</title>
<!--导航栏下-->
<!-- bootstrap的css核心，定义了很多class -->
<link rel="stylesheet" type="text/css" href="/css/bootstrap.css" />
<script type="text/javascript" src="/js/jquery.min.js"></script>
<!--生成弹框、提示框、下拉菜单  -->
<script type="text/javascript" src="/bootstrap/popper.min.js"></script>
<!--bootstrap的js、用于响应事件  -->
<script type="text/javascript" src="/bootstrap/bootstrap.min.js"></script>
<!--导航栏上-->
<!-- for-mobile-apps -->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport"
	content="width=device-width, initial-scale=1, maximum-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="keywords"
	content="Personal Profile Form Widget Responsive, Login form web template, Sign up Web Templates, Flat Web Templates, Login signup Responsive web template, Smartphone Compatible web template, free webdesigns for Nokia, Samsung, LG, SonyEricsson, Motorola web design" />
<!-- //for-mobile-apps -->
<link href='//fonts.googleapis.com/css?family=Questrial'
	rel='stylesheet' type='text/css'>
<link
	href='//fonts.googleapis.com/css?family=Open+Sans:400,300,300italic,400italic,600,600italic,700,700italic,800,800italic'
	rel='stylesheet' type='text/css'>
<link rel="stylesheet" href="/css/j-forms.css">
<link href="/css/style1.css" rel="stylesheet" type="text/css"
	media="all" />
<script type="text/javascript"
	src="http://api.map.baidu.com/api?v=3.0&ak=NEVPuaso46TGp6IAWEyvVnP75mdbGtX4"></script>
<script type="text/javascript" src="/js/jquery.min.js"></script>
<script src="/js/vue.js"></script>
<!--引入axios -->
<script src="/js/axios.js"></script>
</head>
<body>
	<!-- //header -->
	<!--Slider-->
	<div id="navigationBar" class="slider">
		<div class="header-bottom">
			<div class="container">
				<nav class="navbar navbar-default">
					<!-- Brand and toggle get grouped for better mobile display -->
					<div class="navbar-header">
						<button type="button" class="navbar-toggle collapsed"
							data-toggle="collapse"
							data-target="#bs-example-navbar-collapse-1">
							<span class="sr-only">Toggle navigation</span> <span
								class="icon-bar"></span> <span class="icon-bar"></span> <span
								class="icon-bar"></span>
						</button>
						<div class="logo">
							<h1>
								<a class="navbar-brand" href="/index.html">yoga</a>
							</h1>
						</div>
					</div>
					<!-- Collect the nav links, forms, and other content for toggling -->
					<div class="collapse navbar-collapse nav-wil"
						id="bs-example-navbar-collapse-1">
						<nav class="cl-effect-1" id="cl-effect-1">
							<ul class="nav navbar-nav">
								<!--<li><a href="#home" class="active" data-hover="Home">首页</a></li>
								<li><a href="#about" class="scroll" data-hover="About">关于</a></li>-->
								<!--<li><a href="#services" class="scroll" data-hover="Services">私教课程</a></li>-->
								<li><a href="#student" class="scroll" data-hover="student">学员风采</a></li>
								<li v-if="roles != 0"><a href="/ClubMap.html"
									class="scroll" data-hover="Team">场馆地图</a></li>
								<li v-if="roles != 0"><a href="/CoachMap.html"
									class="scroll" data-hover="Team">教练地图</a></li>
								<li v-if="roles == 1||roles == 2"><a href="/student/showMe"
									class="scroll" data-hover="Team">学员信息完善</a></li>
								<li v-if="roles == 1||roles == 3"><a href="/coach/showMe"
									class="scroll" data-hover="Team">教练信息完善</a></li>
								<li v-if="roles == 1||roles == 4"><a
									href="/yogaclub/showMe" class="scroll" data-hover="Team">场馆信息完善</a></li>
								<li><a href="#gallery" class="scroll" data-hover="Projects">会馆图片</a></li>
								<li v-if="roles == -1"><a href="/login.html" class="scroll"
									data-hover="login">登陆</a></li>
								<li v-if="roles == -1"><a href="/register.html"
									class="scroll" data-hover="register">注册</a></li>
								<li v-if="roles == 5"><a href="/adminindex.html"
									class="scroll" data-hover="register">管理</a></li>
								<li
									v-if="roles == 1||roles == 2||roles == 3||roles == 4||roles ==5"><a
									href="/logout">注销</a></li>
								<li>
									<button class="btn btn-default " type="button"
										id="dropdownMenu1" data-toggle="dropdown" aria-haspopup="true"
										aria-expanded="true"
										style="opacity: 0.5; background-color: #4CAF50;"
										v-if="roles == 4">
										我 <span class="caret"></span>
									</button>
									<ul class="dropdown-menu" style="opacity: 0.5"
										v-if="roles == 4">
										<li><a href="#">我的主页</a></li>
										<li><a href="/html/chat.html">信息中心</a></li>
									</ul>
									<button class="btn btn-default dropdown-toggle" type="button"
										id="dropdownMenu2" data-toggle="dropdown" aria-haspopup="true"
										aria-expanded="true" style="opacity: 0.5;" v-if="roles == 3">
										我 <span class="caret"></span>
									</button>
									<ul class="dropdown-menu" aria-labelledby="dropdownMenu2"
										style="opacity: 0.5" v-if="roles == 3">
										<li><a href="/orderShowCoach.html">我的订单</a></li>
										<li><a href="/coachmes.html">我的详情</a></li>
										<li><a href="/pocket.html">我的钱包</a></li>
										<li><a href="/html/chat.html">信息中心</a></li>
									</ul>
									<button class="btn btn-default dropdown-toggle" type="button"
										id="dropdownMenu3" data-toggle="dropdown" aria-haspopup="true"
										aria-expanded="true" style="opacity: 0.5;" v-if="roles == 2">
										我 <span class="caret"></span>
									</button>

									<ul class="dropdown-menu" aria-labelledby="dropdownMenu3"
										style="opacity: 0.5" v-if="roles == 2">
										<li><a href="/orderShowStudent.html">我的订单</a></li>
										<li><a href="/pocket.html">我的钱包</a></li>
										<li><a href="/html/chat.html">信息中心</a></li>
									</ul>

								</li>

							</ul>
						</nav>
					</div>
					<div class="collapse navbar-collapse nav-wil">
						<div class="cl-effect-1" id="cl-effect-2"></div>
					</div>
					<!-- /.navbar-collapse -->
				</nav>
			</div>
		</div>
</div>
		<div class="content">
			<h1>场馆信息，资格认证</h1>
			<div class="main w3l">
				<form class="contact-forms wthree" action="/yogaclub/info">
					<div class="first-line agileits">
						<div class="span6 main-row">
							<div class="input">
								<input type="text" th:value="${yogaclub.yname}"
									placeholder="会馆名称" id="yname" name="yname">
							</div>
						</div>
						<div class="span6 main-row">
							<div class="input">
								<input type="text" th:value="${yogaclub.ytel}" placeholder="电话"
									id="ytel" name="ytel">
							</div>
						</div>
					</div>
					<div class="first-line agileits">
						<div class="span6 main-row">
							<div class="input">
								<input type="email" th:value="${yogaclub.ymail}"
									placeholder="邮箱" id="ymail" name="ymail">
							</div>
						</div>
						<div class="span6 main-row">
							<div class="input">
								<input type="text" th:value="${yogaclub.yqq}" placeholder="QQ"
									id="yqq" name="yqq">
							</div>
						</div>
					</div>
					<div class="main-row">
						<div class="input">
							<input type="text" id="addr" placeholder="地址" name="yaddrmes"
								th:value="${yogaclub.yaddrmes}"> <input type="hidden"
								id="jinwei" placeholder="经纬度" name="yaddress"
								th:value="${yogaclub.yaddress}">
						</div>
					</div>
					<!-- start message -->
					<div class="main-row">
						<div class="input">
							<div id="container" style="width: 99%; height: 300px;"></div>
						</div>
					</div>



					<div class="main-row">
						<div class="input">
							<input type="text" id="addr" placeholder="会馆介绍" name="describe"
								th:value="${yogaclub.describe}">
						</div>
					</div>
					<div class="footer">
						<button type="submit" class="primary-btn">提交</button>
						<button type="reset" class="secondary-btn">重置</button>
					</div>
					<!-- end /.footer -->
				</form>
				<form class="contact-forms wthree" action="/yogaclub/approve">
					<div class="main-row">
						<div class="input">
							<input type="text" th:value="${yogaclub.legalperson}"
								placeholder="负责人" id="legalperson" name="legalperson">
						</div>
					</div>
					<div class="main-row">
						<div class="input">
							<input type="text" th:value="${yogaclub.yidcard}"
								placeholder="身份证" id="yidcard" name="yidcard">
						</div>
					</div>
					<div class="footer">
						<button type="submit" class="primary-btn">发起认证请求</button>
					</div>
				</form>
			</div>
		</div>
		<script>
			$(document).ready(
					function() {
						var map = new BMap.Map("container");
						var point = new BMap.Point(104.0699519292,
								30.5790607666);
						map.centerAndZoom(point, 15);
						map.enableScrollWheelZoom(true);
						map.addControl(new BMap.NavigationControl()); //向地图中添加缩放控件
						var ctrlSca = new window.BMap.ScaleControl({
							anchor : BMAP_ANCHOR_BOTTOM_LEFT
						});
						map.addControl(ctrlSca); //比例尺  
						map.addControl(new BMap.MapTypeControl({
							mapTypes : [ BMAP_NORMAL_MAP, BMAP_SATELLITE_MAP,
									BMAP_HYBRID_MAP ]
						}));

						map.addEventListener("click", function(e) {
							var jinwei = e.point.lng + ", " + e.point.lat;
							$("#jinwei").val(jinwei);
						});
						var geoc = new BMap.Geocoder();
						map.addEventListener("click", function(e) {
							var pt = e.point;
							geoc.getLocation(pt, function(rs) {
								var addComp = rs.addressComponents;
								var context = addComp.province + addComp.city
										+ addComp.district + addComp.street
										+ addComp.streetNumber;
								$("#addr").val(context);
							});
						});

					});
			new Vue({
				el : "#navigationBar",
				data : {
					roles : ""
				},
				beforeCreate : function() {
					var temp = this;

					axios.get("/user/getRoles").then(function(value) {
						temp.roles = value.data
					});

				}
			})
		</script>
</body>
</html>
